package Lrcshow;

public class LrcDao 
{	
	private double time = 0.0f;	
	private String lyric = "";		
	/*	 * 获取时间	 
	 * 
	 */	
	public double getTime()
	{				
		return time;			
		}	
	/*	
	 *  设置时间	 
	 *   tine :被设置成的时间	 
	 * 
	 * */	
	
	public void setTime(double time)
	{		
		this.time = time;	
		
	}	
	/*	
	 *  设置时间	 
	 *  time:被设置成的时间字符串，格式为毫秒数	 
	 * 
	 */	
	 //str[0]为分钟，str[1]为秒钟，str[2]为小数点后的数字	
	  public void setTime(String time )
	  {		
	     String str[] = time.split(":|\\.");
	 	  //this.time = Integer.parseInt(str[0])*60 + Integer.parseInt(str[1]) + Integer.parseInt(str[2])*0.01;		//将这个时间化为毫秒数		
	 	  this.time = Integer.parseInt(str[0])*60*1000 + Integer.parseInt(str[1])*1000 + Integer.parseInt(str[2]);	
	 	  }					
	  /*	 
	   * 获取歌词	
        */	
	  public String getLyric()
	  {				
		  return lyric;	
		  }		
	  public void setLyric(String lyric)
	  {				
		  this.lyric = lyric;	
		  }	
	 }

